package com.fr.base.core.antlr;

import com.fr.base.core.antlr.collections.impl.Vector;

class TreeElement extends AlternativeBlock
{
  GrammarAtom root;

  public TreeElement(Grammar paramGrammar, Token paramToken)
  {
    super(paramGrammar, paramToken, false);
  }

  public void generate()
  {
    this.grammar.generator.gen(this);
  }

  public Lookahead look(int paramInt)
  {
    return this.grammar.theLLkAnalyzer.look(paramInt, this);
  }

  public String toString()
  {
    String str = " #(" + this.root;
    Alternative localAlternative = (Alternative)this.alternatives.elementAt(0);
    for (AlternativeElement localAlternativeElement = localAlternative.head; localAlternativeElement != null; localAlternativeElement = localAlternativeElement.next)
      str = str + localAlternativeElement;
    return str + " )";
  }
}